home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Over 1,000 Windows 95 Programs
/
Over 1000 Windows 95 Programs (Microforum) (Disc 1).iso
/
0105
/
vb.zip
/
LGCAPT.FRM
< prev
next >
Wrap
Text File
|
1996-01-16
|
16KB
|
509 lines
VERSION 2.00
Begin Form CaptionDemo
BackColor = &H00C0C0C0&
BorderStyle = 1 'Fixed Single
Caption = "Captions"
ClientHeight = 3555
ClientLeft = 2340
ClientTop = 1290
ClientWidth = 8625
Height = 3960
Left = 2280
LinkTopic = "Form2"
MaxButton = 0 'False
MDIChild = -1 'True
MinButton = 0 'False
ScaleHeight = 3555
ScaleWidth = 8625
Top = 945
Width = 8745
Begin LGAUGE LGauge1
AutoRedraw = -1 'True
AVersion = 2.501
BackColor = &H00C0C0C0&
BandID = 0
Bands = 1
BevelInner = 0 ' 0 - None
BevelOuter = 1 ' 1 - Raised
BevelWidth = 4
BorderWidth = 0
CaptionID = 0
Captions = 3
FontID = 0
Height = 3405
Left = 240
Orientation = 0 ' 0 - Horizontal
PointerID = 0
Pointers = 3
ScaleID = 0
Scales = 1
TabIndex = 28
TicID = 2
Tics = 3
Top = 60
Width = 4545
ZLoad = LGCAPT.FRX:0000
End
Begin Frame Frame4
BackColor = &H00C0C0C0&
Caption = "Caption Positions"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 975
Left = 4890
TabIndex = 25
Top = 1845
Width = 3645
Begin HScrollBar HScroll1
Height = 240
Index = 0
Left = 885
Max = 100
TabIndex = 27
Top = 330
Width = 2350
End
Begin HScrollBar HScroll1
Height = 240
Index = 1
Left = 885
Max = 100
TabIndex = 26
Top = 570
Width = 2350
End
Begin Label Label2
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "0"
Height = 195
Index = 0
Left = 3300
TabIndex = 5
Top = 345
Width = 120
End
Begin Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "CaptionX:"
FontBold = 0 'False
FontItalic = 0 'False
FontName = "Arial"
FontSize = 8.25
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 210
Index = 0
Left = 180
TabIndex = 9
Top = 330
Width = 690
End
Begin Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "CaptionY:"
FontBold = 0 'False
FontItalic = 0 'False
FontName = "Arial"
FontSize = 8.25
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 210
Index = 1
Left = 195
TabIndex = 11
Top = 570
Width = 705
End
Begin Label Label2
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "0"
Height = 195
Index = 1
Left = 3300
TabIndex = 16
Top = 585
Width = 120
End
End
Begin Frame Frame2
BackColor = &H00C0C0C0&
Caption = "Caption Font ID"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 1095
Left = 6165
TabIndex = 21
Top = 30
Width = 2355
Begin OptionButton Option2
BackColor = &H00C0C0C0&
Caption = "MS Sans Serif (FontID=2)"
FontBold = 0 'False
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 8.25
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 240
Index = 2
Left = 90
TabIndex = 22
Top = 705
Width = 2235
End
Begin OptionButton Option2
BackColor = &H00C0C0C0&
Caption = "Courier(FontID=1)"
FontBold = 0 'False
FontItalic = 0 'False
FontName = "Courier New"
FontSize = 8.25
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 225
Index = 1
Left = 90
TabIndex = 23
Top = 495
Width = 2235
End
Begin OptionButton Option2
BackColor = &H00C0C0C0&
Caption = "Arial (FontID=0)"
FontBold = 0 'False
FontItalic = 0 'False
FontName = "Arial"
FontSize = 8.25
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 240
Index = 0
Left = 90
TabIndex = 24
Top = 285
Width = 1770
End
End
Begin Frame Frame3
BackColor = &H00C0C0C0&
Caption = "Caption Color"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 630
Left = 4890
TabIndex = 4
Top = 1170
Width = 3645
Begin Label Colors
BackColor = &H00000000&
Height = 225
Index = 0
Left = 720
TabIndex = 6
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H000000FF&
Height = 225
Index = 1
Left = 1425
TabIndex = 7
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H00C00000&
Height = 225
Index = 2
Left = 945
TabIndex = 13
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H00404040&
Height = 225
Index = 3
Left = 1650
TabIndex = 14
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H0000FF00&
Height = 225
Index = 4
Left = 1185
TabIndex = 15
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H0000FFFF&
Height = 225
Index = 5
Left = 1890
TabIndex = 17
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H00FFFF00&
Height = 225
Index = 6
Left = 2130
TabIndex = 18
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H00800080&
Height = 225
Index = 7
Left = 2355
TabIndex = 19
Top = 240
Width = 225
End
Begin Label Colors
BackColor = &H000080FF&
Height = 225
Index = 8
Left = 2595
TabIndex = 20
Top = 240
Width = 225
End
End
Begin TextBox Text1
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 360
Left = 4890
TabIndex = 10
Text = " "
Top = 3105
Width = 3645
End
Begin Frame Frame1
BackColor = &H00C0C0C0&
Caption = "Caption ID"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 1095
Left = 4905
TabIndex = 0
Top = 30
Width = 1230
Begin OptionButton Option1
BackColor = &H00C0C0C0&
Caption = "2"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Index = 2
Left = 360
TabIndex = 3
Top = 720
Width = 615
End
Begin OptionButton Option1
BackColor = &H00C0C0C0&
Caption = "1"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Index = 1
Left = 360
TabIndex = 2
Top = 480
Width = 615
End
Begin OptionButton Option1
BackColor = &H00C0C0C0&
Caption = "0"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "System"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Index = 0
Left = 360
TabIndex = 1
Top = 240
Value = -1 'True
Width = 615
End
End
Begin Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "Caption "
Height = 240
Index = 2
Left = 4890
TabIndex = 8
Top = 2880
Width = 720
End
Begin Label Label2
Alignment = 2 'Center
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = " "
Height = 195
Index = 2
Left = 6720
TabIndex = 12
Top = 3030
Width = 90
End
End
Dim colorid(9) As Integer
Sub Colors_Click (index As Integer)
lGauge1.CaptionColor = colors(index).BackColor
text1.ForeColor = lGauge1.CaptionColor
colorid(lGauge1.CaptionID) = index
End Sub
Sub Form_Load ()
hscroll1(0) = lGauge1.CaptionX * 100
hscroll1(1) = lGauge1.CaptionY * 100
text1 = lGauge1.Caption
Option2(lGauge1.CaptionFontID) = True
lGauge1.CaptionID = 0
End Sub
Sub HScroll1_Change (index As Integer)
Select Case index
Case 0
lGauge1.CaptionX = hscroll1(0) / 100
label2(0) = hscroll1(0) / 100
Case 1
lGauge1.CaptionY = hscroll1(1) / 100
label2(1) = hscroll1(1) / 100
End Select
End Sub
Sub HScroll1_Scroll (index As Integer)
Select Case index
Case 0
lGauge1.CaptionX = hscroll1(0) / 100
label2(0) = hscroll1(0) / 100
Case 1
lGauge1.CaptionY = hscroll1(1) / 100
label2(1) = hscroll1(1) / 100
End Select
End Sub
Sub LGauge1_Slide ()
Select Case lGauge1.PointerID
Case 0
lGauge1.PointerID = 0
pstart = lGauge1.PointerStart
pstop = lGauge1.PointerStop
lGauge1.PointerID = 1
lGauge1.PointerValue = pstart
lGauge1.PointerID = 2
lGauge1.PointerValue = pstop
Case 1
lGauge1.PointerID = 1
pstart = lGauge1.PointerValue
lGauge1.PointerID = 0
If pstart > lGauge1.PointerStop - 5 Then
pstart = lGauge1.PointerStop - 5
End If
lGauge1.PointerStart = pstart
lGauge1.PointerID = 1
lGauge1.PointerValue = pstart
Case 2
lGauge1.PointerID = 2
pstop = lGauge1.PointerValue
lGauge1.PointerID = 0
If pstop < lGauge1.PointerStart + 5 Then
pstop = lGauge1.PointerStart + 5
End If
lGauge1.PointerStop = pstop
lGauge1.PointerID = 2
lGauge1.PointerValue = pstop
End Select
End Sub
Sub Option1_Click (index As Integer)
lGauge1.CaptionID = index
hscroll1(0) = lGauge1.CaptionX * 100
hscroll1(1) = lGauge1.CaptionY * 100
text1 = lGauge1.Caption
text1.ForeColor = lGauge1.CaptionColor
Option2(lGauge1.CaptionFontID) = True
End Sub
Sub Option2_Click (index As Integer)
lGauge1.CaptionFontID = index
End Sub
Sub Text1_Change ()
lGauge1.Caption = text1
End Sub